home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-02 / mkmsgsrc.zip / MKMSGABS.PAS < prev    next >
Pascal/Delphi Source File  |  1992-09-19  |  12KB  |  543 lines

  1. Unit MKMsgAbs;       {Abstract Msg Object}
  2.  
  3. {$I MKB.Def}
  4.  
  5. Interface
  6.  
  7. Uses MKGlobT,
  8. {$IFDEF WINDOWS}
  9.   WinDos;
  10. {$ELSE}
  11.   Dos;
  12. {$ENDIF}
  13.  
  14.  
  15. Type MsgMailType = (mmtNormal, mmtEchoMail, mmtNetMail);
  16.  
  17. Type AbsMsgObj = Object
  18.   Constructor Init; {Initialize}
  19.   Destructor Done; Virtual; {Done}
  20.   Procedure SetMsgPath(MP: String); Virtual; {Set msg path/other info}
  21.   Function  OpenMsgBase: Word; Virtual; {Open the message base}
  22.   Function  CloseMsgBase: Word; Virtual; {Close the message base}
  23.   Function  CreateMsgBase(MaxMsg: Word; MaxDays: Word): Word; Virtual;
  24.     {Create new message base}
  25.   Function  MsgBaseExists: Boolean; Virtual; {Does msg base exist}
  26.   Function  LockMsgBase: Boolean; Virtual; {Lock the message base}
  27.   Function  UnLockMsgBase: Boolean; Virtual; {Unlock the message base}
  28.   Procedure SetDest(Var Addr: AddrType); Virtual; {Set Zone/Net/Node/Point for Dest}
  29.   Procedure SetOrig(Var Addr: AddrType); Virtual; {Set Zone/Net/Node/Point for Orig}
  30.   Procedure SetFrom(Name: String); Virtual; {Set message from}
  31.   Procedure SetTo(Name: String); Virtual; {Set message to}
  32.   Procedure SetSubj(Str: String); Virtual; {Set message subject}
  33.   Procedure SetCost(SCost: Word); Virtual; {Set message cost}
  34.   Procedure SetRefer(SRefer: LongInt); Virtual; {Set message reference}
  35.   Procedure SetSeeAlso(SAlso: LongInt); Virtual; {Set message see also}
  36.   Procedure SetDate(SDate: String); Virtual; {Set message date}
  37.   Procedure SetTime(STime: String); Virtual; {Set message time}
  38.   Procedure SetLocal(LS: Boolean); Virtual; {Set local status}
  39.   Procedure SetRcvd(RS: Boolean); Virtual; {Set received status}
  40.   Procedure SetPriv(PS: Boolean); Virtual; {Set priveledge vs public status}
  41.   Procedure SetCrash(SS: Boolean); Virtual; {Set crash netmail status}
  42.   Procedure SetKillSent(SS: Boolean); Virtual; {Set kill/sent netmail status}
  43.   Procedure SetSent(SS: Boolean); Virtual; {Set sent netmail status}
  44.   Procedure SetFAttach(SS: Boolean); Virtual; {Set file attach status}
  45.   Procedure SetReqRct(SS: Boolean); Virtual; {Set request receipt status}
  46.   Procedure SetReqAud(SS: Boolean); Virtual; {Set request audit status}
  47.   Procedure SetRetRct(SS: Boolean); Virtual; {Set return receipt status}
  48.   Procedure SetFileReq(SS: Boolean); Virtual; {Set file request status}
  49.   Procedure DoString(Str: String); Virtual; {Add string to message text}
  50.   Procedure DoChar(Ch: Char); Virtual; {Add character to message text}
  51.   Procedure DoStringLn(Str: String); Virtual; {Add string and newline to msg text}
  52.   Function  WriteMsg: Word; Virtual; {Write msg to msg base}
  53.   Function  GetChar: Char; Virtual; {Get msg text character}
  54.   Function  EOM: Boolean; Virtual; {No more msg text}
  55.   Function  GetString(MaxLen: Word): String; Virtual; {Get wordwrapped string}
  56.   Function  WasWrap: Boolean; Virtual; {Last line was soft wrapped no CR}
  57.   Function  GetFrom: String; Virtual; {Get from name on current msg}
  58.   Function  GetTo: String; Virtual; {Get to name on current msg}
  59.   Function  GetSubj: String; Virtual; {Get subject on current msg}
  60.   Function  GetCost: Word; Virtual; {Get cost of current msg}
  61.   Function  GetDate: String; Virtual; {Get date of current msg}
  62.   Function  GetTime: String; Virtual; {Get time of current msg}
  63.   Function  GetRefer: LongInt; Virtual; {Get reply to of current msg}
  64.   Function  GetSeeAlso: LongInt; Virtual; {Get see also of current msg}
  65.   Function  GetMsgNum: LongInt; Virtual; {Get message number}
  66.   Procedure GetOrig(Var Addr: AddrType); Virtual; {Get origin address}
  67.   Procedure GetDest(Var Addr: AddrType); Virtual; {Get destination address}
  68.   Function  IsLocal: Boolean; Virtual; {Is current msg local}
  69.   Function  IsCrash: Boolean; Virtual; {Is current msg crash}
  70.   Function  IsKillSent: Boolean; Virtual; {Is current msg kill sent}
  71.   Function  IsSent: Boolean; Virtual; {Is current msg sent}
  72.   Function  IsFAttach: Boolean; Virtual; {Is current msg file attach}
  73.   Function  IsReqRct: Boolean; Virtual; {Is current msg request receipt}
  74.   Function  IsReqAud: Boolean; Virtual; {Is current msg request audit}
  75.   Function  IsRetRct: Boolean; Virtual; {Is current msg a return receipt}
  76.   Function  IsFileReq: Boolean; Virtual; {Is current msg a file request}
  77.   Function  IsRcvd: Boolean; Virtual; {Is current msg received}
  78.   Function  IsPriv: Boolean; Virtual; {Is current msg priviledged/private}
  79.   Function  IsDeleted: Boolean; Virtual; {Is current msg deleted}
  80.   Function  IsEchoed: Boolean; Virtual; {Is current msg unmoved echomail msg}
  81.   Function  GetMsgLoc: LongInt; Virtual; {To allow reseeking to message}
  82.   Procedure SetMsgLoc(ML: LongInt); Virtual; {Reseek to message}
  83.   Procedure MsgStartUp; Virtual; {Do message set-up tasks}
  84.   Procedure MsgTxtStartUp; Virtual; {Do message text start up tasks}
  85.   Procedure StartNewMsg; Virtual; {Initialize for adding message}
  86.   Procedure SeekFirst(MsgNum: LongInt); Virtual; {Start msg seek}
  87.   Procedure SeekNext; Virtual; {Find next matching msg}
  88.   Procedure SeekPrior; Virtual; {Prior msg}
  89.   Function  SeekFound: Boolean; Virtual; {Msg was found}
  90.   Procedure YoursFirst(Name: String; Handle: String); Virtual; {Seek your mail}
  91.   Procedure YoursNext; Virtual; {Seek next your mail}
  92.   Function  YoursFound: Boolean; Virtual; {Message found}
  93.   Function  GetHighMsgNum: LongInt; Virtual; {Get highest msg number}
  94.   Procedure SetMailType(MT: MsgMailType); Virtual; {Set message base type}
  95.   Function  GetSubArea: Word; Virtual; {Get sub area number}
  96.   Procedure ReWriteHdr; Virtual; {Rewrite msg header after changes}
  97.   Procedure DeleteMsg; Virtual; {Delete current message}
  98.   Procedure SetEcho(ES: Boolean); Virtual; {Set echo status}
  99.   Function  NumberOfMsgs: LongInt; Virtual; {Number of messages}
  100.   Function  GetLastRead(UNum: LongInt): LongInt; Virtual; {Get last read for user num}
  101.   Procedure SetLastRead(UNum: LongInt; LR: LongInt); Virtual; {Set last read}
  102.   Function  GetMsgDisplayNum: LongInt; Virtual; {Get msg number to display}
  103.   Function  GetTxtPos: LongInt; Virtual; {Get indicator of msg text position}
  104.   Procedure SetTxtPos(TP: LongInt); Virtual; {Set text position}
  105.   End;
  106.  
  107.  
  108. Type AbsMsgPtr = ^AbsMsgObj;
  109.  
  110.  
  111. Implementation
  112.  
  113.  
  114. Constructor AbsMsgObj.Init;
  115.   Begin
  116.   End;
  117.  
  118.  
  119. Destructor AbsMsgObj.Done;
  120.   Begin
  121.   End;
  122.  
  123.  
  124. Procedure AbsMsgObj.SetMsgPath(MP: String);
  125.   Begin
  126.   End;
  127.  
  128.  
  129. Function AbsMsgObj.OpenMsgBase: Word;
  130.   Begin
  131.   End;
  132.  
  133.  
  134. Function AbsMsgObj.CloseMsgBase: Word;
  135.   Begin
  136.   End;
  137.  
  138.  
  139. Function AbsMsgObj.LockMsgBase: Boolean;
  140.   Begin
  141.   End;
  142.  
  143.  
  144. Function AbsMsgObj.UnLockMsgBase: Boolean;
  145.   Begin
  146.   End;
  147.  
  148.  
  149. Procedure AbsMsgObj.SetDest(Var Addr: AddrType);
  150.   Begin
  151.   End;
  152.  
  153.  
  154. Procedure AbsMsgObj.SetOrig(Var Addr: AddrType);
  155.   Begin
  156.   End;
  157.  
  158.  
  159. Procedure AbsMsgObj.SetFrom(Name: String);
  160.   Begin
  161.   End;
  162.  
  163.  
  164. Procedure AbsMsgObj.SetTo(Name: String);
  165.   Begin
  166.   End;
  167.  
  168.  
  169. Procedure AbsMsgObj.SetSubj(Str: String);
  170.   Begin
  171.   End;
  172.  
  173.  
  174. Procedure AbsMsgObj.SetCost(SCost: Word);
  175.   Begin
  176.   End;
  177.  
  178.  
  179. Procedure AbsMsgObj.SetRefer(SRefer: LongInt);
  180.   Begin
  181.   End;
  182.  
  183.  
  184. Procedure AbsMsgObj.SetSeeAlso(SAlso: LongInt);
  185.   Begin
  186.   End;
  187.  
  188.  
  189. Procedure AbsMsgObj.SetDate(SDate: String);
  190.   Begin
  191.   End;
  192.  
  193.  
  194. Procedure AbsMsgObj.SetTime(STime: String);
  195.   Begin
  196.   End;
  197.  
  198.  
  199. Procedure AbsMsgObj.SetLocal(LS: Boolean);
  200.   Begin
  201.   End;
  202.  
  203.  
  204. Procedure AbsMsgObj.SetRcvd(RS: Boolean);
  205.   Begin
  206.   End;
  207.  
  208.  
  209. Procedure AbsMsgObj.SetPriv(PS: Boolean);
  210.   Begin
  211.   End;
  212.  
  213.  
  214. Procedure AbsMsgObj.SetCrash(SS: Boolean);
  215.   Begin
  216.   End;
  217.  
  218.  
  219. Procedure AbsMsgObj.SetKillSent(SS: Boolean);
  220.   Begin
  221.   End;
  222.  
  223.  
  224. Procedure AbsMsgObj.SetSent(SS: Boolean);
  225.   Begin
  226.   End;
  227.  
  228.  
  229. Procedure AbsMsgObj.SetFAttach(SS: Boolean);
  230.   Begin
  231.   End;
  232.  
  233.  
  234. Procedure AbsMsgObj.SetReqRct(SS: Boolean);
  235.   Begin
  236.   End;
  237.  
  238.  
  239. Procedure AbsMsgObj.SetReqAud(SS: Boolean);
  240.   Begin
  241.   End;
  242.  
  243.  
  244. Procedure AbsMsgObj.SetRetRct(SS: Boolean);
  245.   Begin
  246.   End;
  247.  
  248.  
  249. Procedure AbsMsgObj.SetFileReq(SS: Boolean);
  250.   Begin
  251.   End;
  252.  
  253.  
  254. Procedure AbsMsgObj.DoString(Str: String);
  255.   Begin
  256.   End;
  257.  
  258.  
  259. Procedure AbsMsgObj.DoChar(Ch: Char);
  260.   Begin
  261.   End;
  262.  
  263.  
  264. Procedure AbsMsgObj.DoStringLn(Str: String);
  265.   Begin
  266.   End;
  267.  
  268.  
  269. Function AbsMsgObj.WriteMsg: Word;
  270.   Begin
  271.   End;
  272.  
  273.  
  274. Function AbsMsgObj.GetChar: Char;
  275.   Begin
  276.   End;
  277.  
  278.  
  279. Function AbsMsgObj.EOM: Boolean;
  280.   Begin
  281.   End;
  282.  
  283.  
  284. Function AbsMsgObj.GetString(MaxLen: Word): String;
  285.   Begin
  286.   End;
  287.  
  288.  
  289. Function AbsMsgObj.WasWrap: Boolean;
  290.   Begin
  291.   End;
  292.  
  293.  
  294. Procedure AbsMsgObj.SeekFirst(MsgNum: LongInt);
  295.   Begin
  296.   End;
  297.  
  298.  
  299. Procedure AbsMsgObj.SeekNext;
  300.   Begin
  301.   End;
  302.  
  303.  
  304. Function AbsMsgObj.GetFrom: String;
  305.   Begin
  306.   End;
  307.  
  308.  
  309. Function AbsMsgObj.GetTo: String;
  310.   Begin
  311.   End;
  312.  
  313.  
  314. Function AbsMsgObj.GetSubj: String;
  315.   Begin
  316.   End;
  317.  
  318.  
  319. Function AbsMsgObj.GetCost: Word;
  320.   Begin
  321.   End;
  322.  
  323.  
  324. Function AbsMsgObj.GetDate: String;
  325.   Begin
  326.   End;
  327.  
  328.  
  329. Function AbsMsgObj.GetTime: String;
  330.   Begin
  331.   End;
  332.  
  333.  
  334. Function AbsMsgObj.GetRefer: LongInt;
  335.   Begin
  336.   End;
  337.  
  338.  
  339. Function AbsMsgObj.GetSeeAlso: LongInt;
  340.   Begin
  341.   End;
  342.  
  343.  
  344. Function AbsMsgObj.GetMsgNum: LongInt;
  345.   Begin
  346.   End;
  347.  
  348.  
  349. Procedure AbsMsgObj.GetOrig(Var Addr: AddrType);
  350.   Begin
  351.   End;
  352.  
  353.  
  354. Procedure AbsMsgObj.GetDest(Var Addr: AddrType);
  355.   Begin
  356.   End;
  357.  
  358.  
  359. Function AbsMsgObj.IsLocal: Boolean;
  360.   Begin
  361.   End;
  362.  
  363.  
  364. Function AbsMsgObj.IsCrash: Boolean;
  365.   Begin
  366.   End;
  367.  
  368.  
  369. Function AbsMsgObj.IsKillSent: Boolean;
  370.   Begin
  371.   End;
  372.  
  373.  
  374. Function AbsMsgObj.IsSent: Boolean;
  375.   Begin
  376.   End;
  377.  
  378.  
  379. Function AbsMsgObj.IsFAttach: Boolean;
  380.   Begin
  381.   End;
  382.  
  383.  
  384. Function AbsMsgObj.IsReqRct: Boolean;
  385.   Begin
  386.   End;
  387.  
  388.  
  389. Function AbsMsgObj.IsReqAud: Boolean;
  390.   Begin
  391.   End;
  392.  
  393.  
  394. Function AbsMsgObj.IsRetRct: Boolean;
  395.   Begin
  396.   End;
  397.  
  398.  
  399. Function AbsMsgObj.IsFileReq: Boolean;
  400.   Begin
  401.   End;
  402.  
  403.  
  404. Function AbsMsgObj.IsRcvd: Boolean;
  405.   Begin
  406.   End;
  407.  
  408.  
  409. Function AbsMsgObj.IsPriv: Boolean;
  410.   Begin
  411.   End;
  412.  
  413.  
  414. Function AbsMsgObj.IsDeleted: Boolean;
  415.   Begin
  416.   End;
  417.  
  418.  
  419. Function AbsMsgObj.IsEchoed: Boolean;
  420.   Begin
  421.   End;
  422.  
  423.  
  424. Function AbsMsgObj.GetMsgLoc: LongInt;
  425.   Begin
  426.   End;
  427.  
  428.  
  429. Procedure AbsMsgObj.SetMsgLoc(ML: LongInt);
  430.   Begin
  431.   End;
  432.  
  433.  
  434. Procedure AbsMsgObj.MsgStartUp;
  435.   Begin
  436.   End;
  437.  
  438.  
  439. Procedure AbsMsgObj.MsgTxtStartUp;
  440.   Begin
  441.   End;
  442.  
  443.  
  444. Procedure AbsMsgObj.YoursFirst(Name: String; Handle: String);
  445.   Begin
  446.   End;
  447.  
  448.  
  449. Procedure AbsMsgObj.YoursNext;
  450.   Begin
  451.   End;
  452.  
  453.  
  454. Function AbsMsgObj.YoursFound: Boolean;
  455.   Begin
  456.   End;
  457.  
  458.  
  459. Function AbsMsgObj.CreateMsgBase(MaxMsg: Word; MaxDays: Word): Word;
  460.   Begin
  461.   End;
  462.  
  463.  
  464. Function AbsMsgObj.MsgBaseExists: Boolean;
  465.   Begin
  466.   End;
  467.  
  468.  
  469. Procedure AbsMsgObj.StartNewMsg;
  470.   Begin
  471.   End;
  472.  
  473.  
  474. Function AbsMsgObj.GetHighMsgNum: LongInt;
  475.   Begin
  476.   End;
  477.  
  478.  
  479. Function AbsMsgObj.SeekFound: Boolean;
  480.   Begin
  481.   End;
  482.  
  483.  
  484. Procedure AbsMsgObj.SetMailType(MT: MsgMailType);
  485.   Begin
  486.   End;
  487.  
  488.  
  489. Function AbsMsgObj.GetSubArea: Word;
  490.   Begin
  491.   GetSubArea := 0;
  492.   End;
  493.  
  494.  
  495. Procedure AbsMsgObj.ReWriteHdr;
  496.   Begin
  497.   End;
  498.  
  499.  
  500. Procedure AbsMsgObj.DeleteMsg;
  501.   Begin
  502.   End;
  503.  
  504.  
  505. Procedure AbsMsgObj.SetEcho(ES: Boolean);
  506.   Begin
  507.   End;
  508.  
  509.  
  510. Procedure AbsMsgObj.SeekPrior;
  511.   Begin
  512.   End;
  513.  
  514.  
  515. Function AbsMsgObj.NumberOfMsgs: LongInt;
  516.   Begin
  517.   End;
  518.  
  519.  
  520. Function AbsMsgObj.GetLastRead(UNum: LongInt): LongInt;
  521.   Begin
  522.   End;
  523.  
  524. Procedure AbsMsgObj.SetLastRead(UNum: LongInt; LR: LongInt);
  525.   Begin
  526.   End;
  527.  
  528. Function AbsMsgObj.GetMsgDisplayNum: LongInt;
  529.   Begin
  530.   GetMsgDisplayNum := GetMsgNum;
  531.   End;
  532.  
  533. Function AbsMsgObj.GetTxtPos: LongInt;
  534.   Begin
  535.   GetTxtPos := 0;
  536.   End;
  537.  
  538. Procedure AbsMsgObj.SetTxtPos(TP: LongInt);
  539.   Begin
  540.   End;
  541.  
  542. End.
  543.